package tool;

import org.springframework.util.AntPathMatcher;

/**
 * @Description:
 * @Author: yjj
 * @Date: 2025/7/9 12:11
 */

public class Main2 {
    public static void main(String[] args) throws InterruptedException {
        //String url="http://100.124.122.159:8034/v1/servers";
        String url="http://100.124.122.159:8034/v1/servers/4823523838510080480";
        String pathPattern = "/v1/servers/**";
        String path = url.replaceAll("^http://[^/]+", "");
        System.out.println(path);

        AntPathMatcher matcher = new AntPathMatcher();
        boolean matches = matcher.match(pathPattern, path);
        System.out.println("匹配结果：" + matches);
    }
}
